package com.sky.loveshop.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

/**
 * @author xcy
 * @version V1.0
 * @description
 * @date 2024/9/1 11:40
 */
@Controller
public class AliPayViewController {


    /**
     * 下单成功后回调的页面： http://127.0.0.1:8099
     * @param model
     * @return
     */
    @GetMapping("/")
    public String index(Model model) {
        return "index";
    }

    /**
     * 预下单页面： http://127.0.0.1:8099/test
     * @param modelAndView
     * @return
     */
    @RequestMapping("/test")
    public ModelAndView test(ModelAndView modelAndView) {
        modelAndView.setViewName("test");
        return modelAndView;
    }
}
